package ar.com.globallogic.promomr.domain;

public class ContentFiltersChain {
	
	private ContentFilter first;
	
	public ContentFiltersChain(){
		this.first = new DefaultContentFilter();
	}
	
	public void addFilter(ContentFilter filter){
		filter.setNext(this.first);
		this.first = filter;
	}
	
	public void removeFilters(){
		this.first = new DefaultContentFilter();
	}
	
	public boolean passes(User user){
		return this.first.passes(user);
	}
	
	public ContentFilter getFirst(){
		return this.first;
	}

}
